//
//  RTDatePicker.h
//  CustomTabBar
//
//  Created by 张志恒 on 16/4/15.
//  Copyright © 2016年 张志恒. All rights reserved.
//

#import <UIKit/UIKit.h>

@class RTDatePicker;
@protocol RTDatePickerDelegate <NSObject>
@optional
- (void)datePickerDidClickConfirmButton:(RTDatePicker *)picker;
- (void)datePickerDidClickCancelButton:(RTDatePicker *)picker;

@end

@interface RTDatePicker : UIView

@property (nonatomic, weak) id<RTDatePickerDelegate> delegate;

/**
 日期
 */
@property (nonatomic, strong, readonly) NSDate *date;

/**
 日期字符串
 */
@property (nonatomic, copy, readonly) NSString *dateStr;

/**
 日期字符串的格式
 */
@property (nonatomic, strong) NSDateFormatter *formatter;

/**
 默认显示的日期
 */
@property (nonatomic, strong) NSDate *defaultDate;

- (void)show;
- (void)cancel;

@end
